# import pandas
#
# def read_excel(filepaath):
#     getdata = []
#     dy = pandas.read_excel(filepaath)
#     for index, row in dy.iterrows():
#         getdata.append([row['username'], row['password']])
#
#     return getdata
#
#
# print(read_excel('./A3mall_login.xlsx'))



from openpyxl import load_workbook

class read_excel():
    def __init__(self, filepath, shettname):
        self.filepath = load_workbook(filepath)
        self.shettname = self.filepath[shettname]

    def getdata_excel(self):
        datalist = []
        for item in self.shettname:
            list = []
            list.append(item[0].value)
            list.append(item[1].value)
            datalist.append(list)
        datalist.pop(0)
        return datalist


# filepath = r'./A3mall_login.xlsx'
# shettname = 'Sheet1'
# tt = reaf_excel(filepath, shettname)
# print(tt.getdata_excel())




